<template>
  <div>
    <header-comm></header-comm>
    <div class="index" :style="$parent.$parent.collapsed==false?'left: 10%':'left:79px'">
      <div class="sxkj">
        <div class="title">
       <a target="_blank" :href="'https://www.bearing.cn/ybbiz/ebookSet.php?fileName='+$store.state.filename">复制样本目录</a>
        </div>
            
        <div class="exam_structure" @click="copyTreeData">
          {{$store.state.dwmc}}
          <a-icon type="copy" class="ico" style="color:blue;"  />   
    
        </div>

     
        <!-- 开始 树形控件 -->
        <div class="question_info_lists">
          <div class="tre_btn">
           <span class="yctit"> 样册：</span>
            <a-radio-group @change="radiotree" v-model="radiov.ybGroupId">
              <a-radio v-for="(item,i) in radiovalue" :key="i"  :v-if="item.Name!=''" :style="radioStyle" :value="item.ID_NUM">
                {{item.Name}}
                </a-radio>
            </a-radio-group>
          </div>
          <el-row class="add_question" v-show="true">
      
            <a-auto-complete
              :dataSource="$store.state.flnamedata"
              style="width: 70%"
              placeholder="请输入分类名称"
              :filterOption="filterOption"
               v-model="new_question_name"
              @change="onchangevalue"

            />
       
            <a-button
              type="primary"
              @click.stop="add_question_sure"
              class="btn_sure addsub"
            >添加分类</a-button>
           
          </el-row>
          <el-tree
            ref="tree"
            :key="tree_key"
            :data="treeData"
            node-key="id"
            style="font-size:16px; margin-top:20px;"
            @click="routerto(tree_key,treeData)"
            @node-click="handleNodeClick"
            :render-content="renderContent"
            :expand-on-click-node="false"
            :accordion="true"
            :highlight-current="true"
            :default-expanded-keys="defaultExpand"
            :filter-node-method="filterNode"
            :draggable="true"
            :allow-drag="allowdrag"
            @node-drop="handleDrop"
          ></el-tree>
          
        </div>
      </div>
      <transition>
        <yblist v-if="ybgllist"></yblist>
      </transition>
    </div>
  </div>
</template>

<script src="./ybgl.js">
</script>

<style lang='less'>

@import url("./ybgl.less");
</style>
